package com.pro.common.service.pay.enums.init;

import com.pro.common.api.pay.model.db.PayMerchant;
import com.pro.framework.api.enums.IEnumToDbEnum;
import com.pro.framework.javatodb.annotation.JTDField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 路由配置 基础
 */
@Getter
@AllArgsConstructor
public enum EnumPayMerchant implements IEnumToDbEnum<PayMerchant> {
    // 密码123456
    ali("支付宝支付","ali","2021005157600970","{\"rootCertPath\":\"/cert/ali/alipayRootCert.crt\",\"certPath\":\"/cert/ali/appCertPublicKey.crt\",\"alipayPublicCertPath\":\"/cert/ali/alipayCertPublicKey_RSA2.crt\"}","https://openapi.alipay.com/gateway.do",null,null,null,"MIIEowIBAAKCAQEAirESK3XILh76TIgP2xaXOuRpRxCkmPPytZGck6eeu2Y8nU7dHpzjr0+Ym4yHZOFcbAVYBd08kKEpxPGHsv7cItIgTzEQf+yg4DlaegvTDStnvLpWmRYFwNa5cLk4nHU0SJzKq7fiv5hQDsscUvlqhcv08m3YKRURTgePnzNG1yhk50ZVUSJxU0lERLxkYW+llinw1nRMJI/PEV7hrcQksJ17MRKCAyokhBYHMchhLkDM7R+6+W88A9NY+5eOHCKn/ugjOQMrsMA4pyoDQGbKz4SFQCWTveClz74EGFHj/8fD12TEyARst2ahn7ZlO8NVXsnba6loCp2K6348TXBeawIDAQABAoIBAGMgZgUr/LSCLZGvme2UOui7wkcprQspKKr/dPLP1hLI4r/oUwCDT/TIJiHfEhJXRJBsTVp7osMYfVsm6j9UCxDUMIWJYuqbvOwl8fXTJ7h88nsgj66A4AHRNt9LcxvYZVMUxYJwPp+EBIxePVNMswcIHH19ZwcN6L1liBBYPOSgC8PmX/INKCfplWiMzTbzKWfs7kcTAzgTVo+04LPHtb3jVutLZ0iK4a9a5bcX1KP0woX/s7kmg4tEvtlWcWNUPUCfMjoTSHccTE1U0QLAQ+IuL0pnngvmDUC5rhH4co0jSPA4Qo8iPRxCTDs75witJdGWXpu0lB+Xzi6pAlPfnlECgYEAxUHrHME74wsdNZDZ33awT0ptE9JC+jlJf3RglWSjthgeheFH7MWuOXPQqTuN7kE/a7sVxBbRhUKLapSHX2UdDoQbZQc2y9O5Tp/GYXUpJ+I5o1l75w2NP2DQ3H/dHUIN9sqJBr4eVmpmdW+acBvkSBMsqFT5IGuoZkvomhBOyfMCgYEAs/5XbzDelK5wrvSU9mOLeZW1be8mURZ8V8icB5rpoO2E5QWJvVFHSUG09QRpynFZ0QWxOG0F/7fJQuxHOv8np/VAtkCArr9Rpl1zWSxj8HG7kZ44hMGpQlYTd6+X6O3HDzMN4z0hr1IoXgBPGa2/2nKboUTD93oUAb8sQeWs/6kCgYEAk2DFzg0dtmvGXhAkiE5AOm2sA4Q0IIoOvNhxlQzFODbbD0IbH+8uVaSPQPHLADjlrpLwFzrJPhxS18WzQvXj+MWBRkFWkoFU0UaUzJnhrvfaAo7IAQBiCPlH84bg6IxCrKH0MQJ43i3O8Wz54UsliygwVHBwVeW5wvxyBDGs/DsCgYBnvnuK3TINpJXSYarScQHdLIsMOEFvj3RP7JLyVzm9xelJT+3aLtTVxoeUidyoELliHtPM4BoLEFVyu1k7CgJDbrrD0V3aWu+m4kov5cQcvJEOF5IgAreaQp6p5425dgO8IQMqLPwTX1lhBPCSrnDcah6Fz2rcY4LQlu3ddZJHMQKBgAPOS5qNn7CIHWW1Zq5EhabGzQ3Ai5KN553VXtcQLMNOJSlbAmmjBQOXcHNg18D0gtpdkydsLMbppchmFtmpkiVVPdRyCQwQxgRNzNHIoBLaaR6wD2xsI+hze5qzmmcu/j5Q5YGXQS2rmtoMKQEc3kOZefrrSr7BczkVpx3W0fm3",null,null,null,null,null,null,null,null,null,null,null,false, null),
    ;
//    @Schema(description = "商户编号")
//    private final String code;

    @Schema(description = "商户名称")
    private final String name;

    @Schema(description = "商户平台")
    private final String platform;

    @Schema(description = "应用Id", example = "少量支付渠道需要")
    private final String appId;

    @Schema(description = "补充JSON配置", example = "支付宝或微信等大平台可能需要其他额外参数")
    private final String extendConfigJson;

    // ===== 代收基础配置（Payment） =====

    @Schema(description = "代收接口地址")
    private final String paymentRequestUrl;

    @Schema(description = "代收商户号")
    private final String paymentMchId;

    @Schema(description = "代收密钥（秘钥或私钥）")
    private final String paymentMchKey;

    @Schema(description = "代收公钥（用于加密/验签）")
    private final String paymentPublicKey;

    @Schema(description = "代收私钥（用于签名）")
    private final String paymentPrivateKey;

    @Schema(description = "代收回调验签用公钥（部分通道回调用此）")
    private final String paymentCallbackPublicKey;

    @Schema(description = "代收回调签名用私钥（如果回调时我方需要签名）")
    private final String paymentCallbackPrivateKey;

    // ===== 代付基础配置（Payout） =====

    @Schema(description = "代付接口地址")
    private final String payoutRequestUrl;

    @Schema(description = "代付商户号")
    private final String payoutMchId;

    @Schema(description = "代付密钥（秘钥或私钥）")
    private final String payoutMchKey;

    @Schema(description = "代付公钥（用于加密/验签）")
    private final String payoutPublicKey;

    @Schema(description = "代付私钥（用于签名）")
    private final String payoutPrivateKey;


    @Schema(description = "代付回调验签用公钥")
    private final String payoutCallbackPublicKey;

    @Schema(description = "代付回调签名用私钥")
    private final String payoutCallbackPrivateKey;

    // ===== 其他配置 =====

    @Schema(description = "是否是线下支付")
    private final Boolean offlineFlag;

    @Schema(description = "白名单")
    private final String whitelist;

    @Schema(description = "管理端显示")
    @JTDField(defaultValue = "1")
    private final Boolean showAdmin;
    /**
     * 统一重置修改掉,这个配置时间以前的,旧的配置
     */
    private final String forceChangeTime;
}
